﻿<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<c:set var="ctx" value="${pageContext.request.contextPath}"/>
<html>
<head><link rel="stylesheet" href="${ctx}/common/common.css">
    <title>检验报告</title>
    <link rel="stylesheet" href="${ctx}/common/plugins/layuiadmin/layui/css/layui.css" media="all">
    <link rel="stylesheet" href="${ctx}/common/plugins/layuiadmin/style/admin.css" media="all">
    <script src="${ctx}/common/plugins/layuiadmin/layui/layui.js"></script>
    
    <script src="${ctx}/common/plugins/publicJs/publicJs.js"></script>
    <style>
        .layui-body{overflow-y: scroll;}
        
    </style>
</head>
<body>
<!--主体内容层-->
<input type="hidden" id="purDetailId" value="${purDetailId}">
<div class="layui-fluid">
	<div class="layui-col-md12" style="padding-top: 10px;padding-bottom: 10px">
        <div style="float: right;" class="layui-btn-group paramBtn">
            <button id="rollback" type="button" class="layui-btn layui-btn-sm layui-btn-danger">
               返回
            </button>
        </div>
    </div>
    <div class="layui-row layui-col-space15">
        <div class="layui-col-md12 layui-col-space15">
            <table class="layui-table" id="inspectionReload" lay-data="{ url:'${ctx}/purchaseStatistics/findInspectionPage?recipientId=${recipientId}', page:false}" lay-filter="demo">
                <thead>
                <tr>
                    <th lay-data="{field:'code'}">检验单号</th>
                    <th lay-data="{field:'name'}">检验产品</th>
                    <th lay-data="{field:'product_batch'}">生产批次</th>
                    <th lay-data="{field:'product_date'}">生产日期</th>
                    <th lay-data="{field:'inspPerson'}">检验人员</th>
                    <th lay-data="{field:'insp_type'}">检验方式</th>
                    <th lay-data="{field:'insp_org'}">检验机构</th>
                    <th lay-data="{field:'insp_date'}">检验时间</th>
                    <th lay-data="{field:'sample_size'}">样本量</th>
                    <th lay-data="{field:'insp_result'}">检验结果</th>
                </tr>
                </thead>
            </table>
        </div>
    </div>
</div>
</body>
<script>
	layui.use(['tree','layer','table'], function () {
		var $=layui.$;
    	var loading=layer.msg("数据加载中...");
        var table = layui.table;
        table.render({
            done:function(){
                layer.close(loading);
            }
        })
        var ins;
        //监听filter为demo的table中的工具条
        table.on('tool(demo)', function (obj) {
            var data = obj.data;
        });

        $('.demoTable .layui-btn').on('click', function () {
            var type = $(this).data('type');
            active[type] ? active[type].call(this) : '';
        });
        //给按钮绑定active中的方法
        $(".paramBtn .layui-btn").on("click", function () {
            var type = $(this).data('type');
            //查看是active这个json中是否有type这个方法，如果有调用，如果没有不知心；
            active[type] ? active[type].call() : '';
        })
        

    });
	document.getElementById("rollback").addEventListener("click",function(){
        window.history.back();
    })
</script>
</html>



